package com.shop.dingdongshoppingapi.controller;

import com.shop.dingdongshoppingapi.dto.RemarksAddDto;
import com.shop.dingdongshoppingapi.service.intf.RemarksService;
import com.shop.dingdongshoppingapi.vo.R;
import io.swagger.annotations.Api;
import org.springframework.web.bind.annotation.*;

import javax.annotation.Resource;
import javax.servlet.http.HttpServletRequest;

@RestController
@RequestMapping("/api/remarks/")
@Api
@CrossOrigin
public class RemarksController {
    @Resource
    private RemarksService service;
    @PostMapping("save.do")
    public R sava(@RequestBody RemarksAddDto dto){
        return service.save(dto);
    }
    @GetMapping("query.do")
    public R query(int oid){
        return service.query(oid);
    }

}
